x86/HVM: honor p2m_ram_ro in hvm_map_guest_frame_rw()
authorJan Beulich <jbeulich@suse.com>
Fri, 14 Aug 2015 10:36:26 +0000 (12:36 +0200)
committerJan Beulich <jbeulich@suse.com>
Fri, 14 Aug 2015 10:36:26 +0000 (12:36 +0200)
commit672101b54269d7a69c2ccaa345ea396dcca63238
tree4874c5bd22bf09c6459c78ed918fe157096329b7
parentb001c41cf2da767127ed5ebb7d906d4a284afad7
x86/HVM: honor p2m_ram_ro in hvm_map_guest_frame_rw()

... and its callers.

While all non-nested users are made fully honor the semantics of that
type, doing so in the nested case seemed insane (if doable at all,
considering VMCS shadowing), and hence there the respective operations
are simply made fail.

One case not (yet) taken care of is that of a page getting transitioned
to this type after a mapping got established.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Kevin Tian <kevin.tian@intel.com>
Release-acked-by: Wei Liu <wei.liu2@citrix.com>
xen/arch/x86/hvm/hvm.c
xen/arch/x86/hvm/svm/nestedsvm.c
xen/arch/x86/hvm/vmx/vmx.c
xen/arch/x86/hvm/vmx/vvmx.c
xen/include/asm-x86/hvm/hvm.h